package com.ruoyi.assets.dto;

import com.ruoyi.assets.enums.VisitTypeEnum;
import io.micrometer.common.util.StringUtils;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

/**
 * @author dg
 */
@Data
public class StateVisitDTO {
    @NotNull(message = "type不能为空")
    private VisitTypeEnum type;
    @NotBlank(message = "code不能为空")
    private String code;
    private String id;

    public String getId() {
        if (StringUtils.isBlank(id)) {
            return "";
        }
        return id;
    }
}
